package com.org.gundutubruk;

import android.app.Activity;
import android.content.Intent;
import android.os.Bundle;
import android.view.Window;
import android.view.WindowManager;
import android.widget.TextView;

public class GameHelpActivity extends Activity {
	
	@Override
	protected void onCreate(Bundle savedInstanceState) {
		super.onCreate(savedInstanceState);
		requestWindowFeature(Window.FEATURE_NO_TITLE);		
		getWindow().setFlags(WindowManager.LayoutParams.FLAG_FULLSCREEN, WindowManager.LayoutParams.FLAG_FULLSCREEN);
		
		this.setContentView(R.layout.help_layout);
		String[] helps = this.getResources().getStringArray(R.array.game_help);
		TextView tv = (TextView) this.findViewById(R.id.helptext);
		tv.setText(helps[GameSettingHolder.modegame-1]);
	}
	
	@Override
	public void onBackPressed() {
		prevact();
	}
	
	private void prevact() {
		this.startActivity(new Intent("android.intent.action.GAMEMODE"));
		overridePendingTransition(R.anim.fade, R.anim.hold);
		this.finish();
	}
}
